﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace _018
{
    /// <summary>
    /// 编译时多态
    /// </summary>
    internal class Program
    {
        void print(int i)
        {
            Console.WriteLine("打印int类型的数据：{0}",i);
        }
        void print(double d)
        {
            Console.WriteLine("打印double类型的数据：{0}",d);
        }
        void print(string s)
        {
            Console.WriteLine("打印string类型的数据：{0}",s);
        }
        static void Main(string[] args)
        {
            Program p = new Program();
            p.print(123);
            p.print("Hello World");
            p.print(3.1415926);
            Console.ReadKey();

        }
    }
}
